//
//  KYAboutController.m
//  KYKJPackDemo
//
//  Created by Jordan zhou on 2017/9/25.
//  Copyright © 2017年 ???. All rights reserved.
//

#import "KYAboutController.h"
#import "KYAppInfoView.h"

@interface KYAboutController ()

@end

@implementation KYAboutController
- (void)viewDidLoad {
    [super viewDidLoad];
    
    // 0.设置headerView
    [self setUpHeaderView];
    
    // 1.添加分组
    [self setUpGroup0];
}

/**
 *  设置头部标题
 */
- (void)setUpHeaderView
{
    KYAppInfoView *infoView = [KYAppInfoView customInfoView];
    infoView.frame = CGRectMake(0, 0, self.view.frame.size.width, self.view.frame.size.height * 0.4);
    self.tableView.tableHeaderView = infoView;
}

/**
 *  显示一组
 */
- (void)setUpGroup0
{
    KYSettingGroup *group = [self addGroup];
    
    KYSettingItem *appVersion = [KYSettingItem itemWithTitle:NSLocalizedString(@"版本号", nil)];
    appVersion.detailLabel = NSLocalizedString(@"1.1.0", nil);
    
    KYSettingItem *serialNumber = [KYSettingItem itemWithTitle:NSLocalizedString(@"序列号", nil)];
    serialNumber.detailLabel = NSLocalizedString(@"01234567890100", nil);
    
    group.items = @[appVersion,serialNumber];
    
}

@end
